﻿using AutoMapper;
using MappingDTO.Configure;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace MappingDTO
{
    public class MappingConfig 
    {
        public static void ConfigureInit()
        {
            Mapper.Initialize(cfg =>
            {
                cfg.AddProfile<AuthorityConfigure>();
                cfg.AddProfile<AdminConfigure>();

                //cfg.AddProfile<Profiles.OrderDtoProfile>();

                //cfg.ForAllMaps((a, b) => b.ForAllMembers(opt => opt.Condition((src, dest, sourceMember) => sourceMember != null)));
            });
        }
    }
}
